﻿using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Text;
using T.FAS.Runtime.Base.Entity;

namespace T.FAS.Runtime.Metadata.Entity.DataModel
{
    /// <summary>
    /// 规则定义
    /// </summary>
    public class TRuleField : ICloneable
    {
        /// <summary>
        /// 主键id
        /// </summary>
        public string ID { get; set; }

        /// <summary>
        /// 所属状态机ID
        /// </summary>
        [JsonIgnore]
        public string StateMachineID { get; set; }

        /// <summary>
        /// 所属状态ID
        [JsonIgnore]
        /// </summary>
        public string StateID { get; set; }

        /// <summary>
        /// 规则标识
        /// </summary>
        [JsonIgnore]
        public string RuleID { get; set; }

        /// <summary>
        /// 规则应用字段Code
        /// </summary>
        public string ColumnName { get; set; }

        /// <summary>
        /// 规则应用字段中文名，用于报错提示
        /// </summary>
        public string DisplayName { get; set; }

        /// <summary>
        /// 排序
        /// </summary>
        public int Sort { get; set; }

        /// <summary>
        /// 创建人
        /// </summary>
        [JsonIgnore]
        public string Creator { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>     
        [JsonIgnore]
        public DateTime CreateTime { get; set; }

        /// <summary>
        /// 最后修改人
        /// </summary>
        [JsonIgnore]
        public string LastModifier { get; set; }

        /// <summary>
        /// 最后修改时间
        /// </summary>     
        [JsonIgnore]
        public DateTime LastModifyTime { get; set; }

        public object Clone()
        {
            return this.MemberwiseClone();
        }
    }
}
